<?xml version="1.0" encoding="UTF-8"?>
<!--
To change this template, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core">

    <h:head>
        <title>Ajax</title>
    </h:head>
    <h:body>
        <h:form id="formid" >
            Time : #{ajaxManagedBean.timenow} <br />
            <h:outputText value="Tpye here : "/>
            <h:inputText value="#{ajaxManagedBean.str}" required="true" />&nbsp;
            <h:commandButton action="#{ajaxManagedBean.echo}" value="AJAX BTN" >
                <f:ajax execute="@form" render="formid:resultid" />
            </h:commandButton>&nbsp;
            <h:commandButton action="#{ajaxManagedBean.echo}" value="OK" /><br />
            <b><h:outputText value="#{ajaxManagedBean.echoStr}" id="resultid" /></b>
        </h:form>
    </h:body>
</html>
